Platform Explorer / Nuxeo Platform LTS 2017 9.10

Contribution org.nuxeo.ecm.multi.tenant.layouts--widgets

This contribution is part of XML component org.nuxeo.ecm.multi.tenant.layouts inside nuxeo-multi-tenant-jsf-9.10.jar /OSGI-INF/layouts-contrib.xml

Extension Point

Extension point widgets of component WebLayoutManager.

Contributed Items

  • <widget name="tenantId" type="selectOneMenu">
          <labels>
            <label mode="any">label.tenant.id</label>
          </labels>
          <translated>true</translated>
          <fields>
            <field>user:tenantId</field>
          </fields>
          <widgetModes>
            <mode value="editPassword">********</mode>
            <mode value="create">#{nxu:test(multiTenantActions.isTenantIsolationEnabled()
                and webActions.checkFilter('only_for_manager'), 'edit', 'hidden')}</mode>
            <mode value="edit">#{nxu:test(multiTenantActions.isTenantIsolationEnabled()
                and webActions.checkFilter('only_for_manager'), 'edit', 'hidden')}</mode>
            <mode value="view">hidden</mode>
          </widgetModes>
          <selectOptions>
            <option itemLabel="None" itemValue=""/>
            <options itemLabel="#{doc.tenant.label}" itemValue="#{doc.tenant.id}" value="#{multiTenantActions.tenants}" var="doc"/>
          </selectOptions>
        </widget>
  • <widget name="tenantIdView" type="text">
          <labels>
            <label mode="any">label.tenant.id</label>
          </labels>
          <translated>true</translated>
          <fields>
            <field>user:tenantId</field>
          </fields>
          <widgetModes>
            <mode value="editPassword">********</mode>
            <mode value="create">hidden</mode>
            <mode value="edit">hidden</mode>
            <mode value="view">#{nxu:test(multiTenantActions.isTenantIsolationEnabled()
              and webActions.checkFilter('only_for_manager'), 'view', 'hidden')}</mode>
          </widgetModes>
        </widget>
  • <widget name="userTenantId" type="layout">
          <properties mode="any">
            <property name="name">user_tenant_id</property>
          </properties>
        </widget>

XML Source

<extension point="widgets" target="org.nuxeo.ecm.platform.forms.layout.WebLayoutManager">

    <widget name="tenantId" type="selectOneMenu">
      <labels>
        <label mode="any">label.tenant.id</label>
      </labels>
      <translated>true</translated>
      <fields>
        <field>user:tenantId</field>
      </fields>
      <widgetModes>
        <mode value="editPassword">********</mode>
        <mode value="create">#{nxu:test(multiTenantActions.isTenantIsolationEnabled()
            and webActions.checkFilter('only_for_manager'), 'edit', 'hidden')}</mode>
        <mode value="edit">#{nxu:test(multiTenantActions.isTenantIsolationEnabled()
            and webActions.checkFilter('only_for_manager'), 'edit', 'hidden')}</mode>
        <mode value="view">hidden</mode>
      </widgetModes>
      <selectOptions>
        <option itemLabel="None" itemValue=""/>
        <options itemLabel="#{doc.tenant.label}" itemValue="#{doc.tenant.id}" value="#{multiTenantActions.tenants}" var="doc"/>
      </selectOptions>
    </widget>
    <widget name="tenantIdView" type="text">
      <labels>
        <label mode="any">label.tenant.id</label>
      </labels>
      <translated>true</translated>
      <fields>
        <field>user:tenantId</field>
      </fields>
      <widgetModes>
        <mode value="editPassword">********</mode>
        <mode value="create">hidden</mode>
        <mode value="edit">hidden</mode>
        <mode value="view">#{nxu:test(multiTenantActions.isTenantIsolationEnabled()
          and webActions.checkFilter('only_for_manager'), 'view', 'hidden')}</mode>
      </widgetModes>
    </widget>

    <widget name="userTenantId" type="layout">
      <properties mode="any">
        <property name="name">user_tenant_id</property>
      </properties>
    </widget>

  </extension>